from peewee import *

database = MySQLDatabase('laoxu', **{'charset': 'utf8', 'sql_mode': 'PIPES_AS_CONCAT', 'use_unicode': True, 'host': '192.168.10.166', 'port': 3306, 'user': 'a', 'password': '110'})

class UnknownField(object):
    def __init__(self, *_, **__): pass

class BaseModel(Model):
    class Meta:
        database = database

class CarsAudiAll(BaseModel):
    pid = CharField(max_length=30,default='',index=True,verbose_name='零件号',help_text='零件号')
    standard_label = CharField(max_length=256,default='',verbose_name='标准零件名称',help_text='标准零件名称')
    label = CharField(max_length=800, default='', verbose_name='零件名称', help_text='零件名称')
    engine_code = CharField(max_length=800,default='',verbose_name='发动机代码',help_text='发动机代码')
    cylinder = CharField(max_length=30,default='',verbose_name='缸数',help_text='缸数')
    transmission = CharField(max_length=256,default='',verbose_name='变速箱配置',help_text='变速箱配置')
    replace = CharField(max_length=256,default='',verbose_name='替换',help_text='替换')
    drive = CharField(max_length=128, default='', verbose_name='驱动方式', help_text='驱动方式')
    diff_mech = CharField(max_length=128,default='',verbose_name='差速器配置',help_text='差速器配置')
    displacement = CharField(max_length=128,default='',verbose_name='排量',help_text='排量')

    class Meta:
        table_name = 'cars_audi_All'
        verbose_name = '奥迪'

